{extend name="common:base" /}
{block name="css"}
<!--pickers css-->
<link rel="stylesheet" type="text/css" href="__JS__/bootstrap-datepicker/css/datepicker-custom.css" />
<link rel="stylesheet" type="text/css" href="__JS__/bootstrap-timepicker/css/timepicker.css" />
<link rel="stylesheet" type="text/css" href="__JS__/bootstrap-colorpicker/css/colorpicker.css" />
<link rel="stylesheet" type="text/css" href="__JS__/bootstrap-daterangepicker/daterangepicker-bs3.css" />
<link rel="stylesheet" type="text/css" href="__JS__/bootstrap-datetimepicker/css/datetimepicker-custom.css" />
{/block}
{block name="main"}
<!--body wrapper start-->
<div class="wrapper">
    <div class="row">
        <div class="col-md-12">
            <!--breadcrumbs start -->
            <ul class="breadcrumb panel">
                <li><a href="{:url('Index/index')}"><i class="fa fa-home"></i> 控制台</a></li>
                <li><a href="{:url('index')}">会员管理</a></li>
                <li class="active">登陆历史</li>
            </ul>
            <!--breadcrumbs end -->
        </div>
    </div>
    <div class="row">
        <div class="col-sm-12">
            <section class="panel">
                <header class="panel-heading col-xs-12">

                    <form class="form-inline" action="{:url('')}">
                        <div class="form-group">
                            <div class="col-md-3">
                                <div class="input-group  custom-date-range">
                                    <input type="text" class="form-control form_datetime" value="{$_GET['from'] ?? ''}" name="from" placeholder="开始时间">
                                    <span class="input-group-addon">到</span>
                                    <input type="text" class="form-control form_datetime" value="{$_GET['to'] ?? ''}" name="to" placeholder="结束时间">
                                </div>
                            </div>
                            <input type="text" name="mobile" class="form-control" value="{$_GET['mobile'] ?? ''}" placeholder="请输入手机号码">
                            <select class="form-control" name="login_way">
                                <option value="0">请选择登陆方式</option>
                                <option value="1">安卓</option>
                                <option value="2">IOS</option>
                                <option value="3">Web</option>
                            </select>
                            <button type="submit" class="btn btn-primary"><i class="fa fa-search"></i></button>
                        </div>
                    </form>
                </header>

                <div class="panel-body">
                    <form class="ids" action="{:url('del')}" method="post">
                        <table class="table">
                            <thead>
                            <tr>
                                <!--<th><input class="check-all" type="checkbox"/></th>-->
                                <th>ID</th>
                                <th>电话</th>
                                <th>昵称</th>
                                <th>IP</th>
                                <th>地址</th>
                                <th>方式</th>
                                <th>距上次登陆时间</th>
                                <th>时间</th>
                            </tr>
                            </thead>
                            <tbody>
                            {volist name='list' id='v'}
                            <tr>
                                <!--<td><input class="ids" type="checkbox" value="{$v.id}" name="ids[]"/></td>-->
                                <td>{$v.id}</td>
                                <td>{$v.member.mobile}</td>
                                <td>{$v.member.nickname}</td>
                                <td>{$v.ip}</td>
                                <td>{$v.ip_address}</td>
                                <td>{if $v.login_way==1}
                                    安卓
                                    {elseif $v.login_way==2}
                                    IOS
                                    {else/}
                                    Web
                                    {/if}
                                </td>
                                <td>{$v.minute}小时</td>


                                <td>{if (isTimeZero($v.create_at))}{$v.create_at}{/if}</td>
                            </tr>
                            {/volist}

                            </tbody>
                        </table>
                    </form>

                    <!--<a href="{:url('del')}" class="btn btn-sm btn-primary ajax-post confirm" target-form="ids">批量删除</a>-->

                </div>
            </section>
            {$page}
        </div>

    </div>
</div>
<!--body wrapper end-->
{/block}
<!-- modal -->
{block name="js"}
<!--pickers plugins-->
<script type="text/javascript" src="__JS__/bootstrap-datepicker/js/bootstrap-datepicker.js"></script>
<script type="text/javascript" src="__JS__/bootstrap-datetimepicker/js/bootstrap-datetimepicker.js"></script>
<script type="text/javascript" src="__JS__/bootstrap-daterangepicker/moment.min.js"></script>
<script type="text/javascript" src="__JS__/bootstrap-daterangepicker/daterangepicker.js"></script>
<script type="text/javascript" src="__JS__/bootstrap-colorpicker/js/bootstrap-colorpicker.js"></script>
<script type="text/javascript" src="__JS__/bootstrap-timepicker/js/bootstrap-timepicker.js"></script>

<!--pickers initialization-->
<script src="__JS__/pickers-init.js"></script>
{/block}
